home *** CD-ROM | disk | FTP | other *** search
/ The CICA Windows Explosion! / The CICA Windows Explosion! - Disc 1.iso / games / minehl1a.zip / MINEHELP.DOC next >
Text File  |  1993-05-29  |  6KB  |  166 lines

  1. MINEHELP.EXE
  2. ============
  3.  
  4. MineHelp is a little nonsense program which assists you with the Minesweeper
  5. game included in Windows 3.1. It is able to solve the simple parts of the
  6. puzzle, leaving only the really challenging ones to you.
  7.  
  8. This program is free, no warranties of course. It should always be
  9. distributed as a package containing MINEHELP.EXE, MINEHELP.PAS (TPW source
  10. code), MINEHELP.RES (resource file) and MINEHELP.DOC (this document).
  11.  
  12. Description
  13. ===========
  14.  
  15. You can start MineHelp at any time. When Minesweeper is not active, MineHelp
  16. just sits and waits; as soon as Minesweeper is started, MineHelp begins to
  17. analyze the game situation.
  18.  
  19. When started, MineHelp displays a little dialog box:
  20.  
  21. Status:
  22. -------
  23.   Inactive:  MineHelp doesn't do anything.
  24.  
  25.   Active:    When you press the OK button, MineHelp will do one step towards
  26.              the solution of the puzzle, according to the "Level" settings.
  27.              If it doesn't find a move, it does nothing, and it is up to
  28.              you to figure out the next step.
  29.  
  30.   Automatic: MineHelp continuously monitors the mine field and does what it
  31.              can do to solve the puzzle. It will only stop when there is no
  32.              obvious thing to do (and "Level" is not set to "Random").
  33.  
  34. Level:
  35. ------
  36.   Basic:     MineHelp will only do the basic tricks: clearing around a square
  37.              if there are already enough squares marked as mined, or marking
  38.              all covered adjacent squares if their number adds up to the
  39.              total number of mines.
  40.  
  41.   Expert:    MineHelp will also solve problems which depend on two numbered
  42.              squares. Here is a typical situation:
  43.  
  44.              .::,      (X means any numbered field)
  45.              X21,      The ':' region contains one mine at most, but the '2'
  46.              XXX,      square needs two mines in its neighbourhood. Hence,
  47.                        '.' is a mine, and the ',' fields are all safe. 
  48.  
  49.   Random:    If it doesn't find a move using the "basic" and "expert"
  50.              strategies, MineHelp will uncover a square at random. This can
  51.              go wrong, of course.
  52.  
  53. Animation:   MineHelp will move the mouse cursor around on the mine field
  54. ----------   while it simulates mouse clicks.
  55.  
  56.  
  57. Remarks:  - If "Status" is "Automatic" and "Level" is "Random", MineHelp
  58. ========    effectively attempts to solve the puzzle without user interaction.
  59.  
  60.           - These options take effect immediately; there's no need to press
  61.             the OK button. The OK button is only for single-step execution
  62.             in "active" mode.
  63.  
  64. Command line arguments
  65. ======================
  66.  
  67. The program parameter is a single string of lowercase (sorry) characters.
  68.  
  69.   c: MineHelp will start iconized
  70.   h: MineHelp will start hidden (and probably remain so)
  71.   i: initial status will be "inactive"
  72.   a: initial status will be "active"
  73.   b: initial level will be "basic"
  74.   r: initial level will be "random"
  75.   n: animation will be on initially.
  76.  
  77. Defaults: window visible, status automatic, level expert, animation off.
  78.  
  79. Example: minehelp cab   -> Start iconized, status is active, level is basic.
  80.  
  81. How it works
  82. ============
  83.  
  84. MineHelp analyzes the Minesweeper window by finding its position on the
  85. screen and then examining the contents of the mine field squares. It does
  86. this by reading pixels at strategic locations, using Windows' GetPixel
  87. function.
  88.  
  89. The program then analyzes the current situation and sends the appropriate
  90. mouse clicks to the Minesweeper window.
  91.  
  92. In "automatic" mode, MineHelp uses a timer to examine the mine field once
  93. every second.
  94.  
  95. Limitations
  96. ===========
  97.  
  98. - MineHelp works only when Minesweeper is in color mode.
  99.  
  100. - MineHelp doesn't do anything if the mine field is not fully visible
  101.   on the screen.
  102.  
  103. - The program relies on the Minesweeper window dimensions and on the
  104.   colors and shapes of the bitmaps used for the squares. If this should
  105.   change with future Minesweeper versions, MineHelp would stop working. 
  106.  
  107. - MineHelp doesn't make mistakes (hopefully), except in "Random" mode;
  108.   however, it always assumes that the marks on the mine field are correct.
  109.  
  110. - In automatic mode, you cannot safely use the "?" feature, because the
  111.   first right mouse click will produce a "mark", which is taken literally
  112.   by MineHelp.
  113.  
  114. - In automatic mode, Minesweeper sometimes loses the "button up" message
  115.   from a *user's* mouse click. This leaves the clicked square in a "pushed"
  116.   state, which looks like a safe field with no mines around it to MineHelp.
  117.  
  118. - MineHelp doesn't work with some buggy video drivers. Among those are the
  119.   ET4000 "turbo" drivers (MMTL*.DRV), which return incorrect values for the
  120.   GetPixel function. 
  121.  
  122. Performance
  123. ===========
  124.  
  125. In automatic/random mode, MineHelp solves Minesweeper's "Expert" mode in
  126. about 20% of all cases.
  127.  
  128. The time used to solve the puzzle depends of course on the processor
  129. speed, but also on the speed of the video driver. On a Compaq 486/50M
  130. with QVision card, the best score was 5 seconds (usually 7 to 10). On
  131. a 386/20, times are around 50 seconds.
  132.  
  133. What could be improved
  134. ======================
  135.  
  136. - MineHelp doesn't take into account the number of remaining mines displayed
  137.   in the upper left corner of Minesweeper's window. This information is
  138.   often useful in the final phases of the game.
  139.  
  140. - "Random" mode does not have to be completely random; there could be some
  141.   basic probability calculations.
  142.  
  143. - MineHelp cannot solve problems which depend on more than two numbered
  144.   squares. These situations are quite rare, but here's a simple one:
  145.  
  146.   XXX     The '.' and ',' regions both contain exactly one mine, therefore
  147.   .1XX    ':' is safe.
  148.   .21X
  149.   :,,X
  150.  
  151. History
  152. =======
  153.  
  154. Version 1.00, April 26, 1992.
  155. Version 1.01, May 8, 1993:
  156.   - Small change in the "two fields" strategy
  157.   - Correct class name in the dialog resource
  158.   - Documentation changes.
  159. Version 1.02, May 29, 1993:
  160.   - "Internationalized" version, uses GetClassName() rather than
  161.     GetWindowText() to detect Minesweeper.
  162.  
  163.  
  164. Have fun....                    Peter Karrer      pkarrer@bernina.ethz.ch
  165.                                                   100121,2215
  166.